package com.lingchen.boot.gof.singleton;

/**
 * Created by lc on 2020/6/22
 */
public class SingleModel {

    private static SingleModel singleModel;


    private SingleModel() {

    }

    public static SingleModel getInstance() {
        if (singleModel == null) {
            synchronized (SingleModel.class) {
                if (null == singleModel) {
                    singleModel = new SingleModel();
                }
            }
        }
        return singleModel;
    }


}
